]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
network: Update the icon in the panel whenever NM's state changes
authorMario Sanchez Prada <mario@endlessm.com>
Tue, 17 Apr 2018 20:51:34 +0000 (21:51 +0100)
committerMario Sanchez Prada <mario@endlessm.com>
Tue, 15 May 2018 08:15:43 +0000 (09:15 +0100)
Similar to what it's done when the main connection changes, we need
to make sure that the icon in the panel gets updated before calling
_syncConnectivity(), so that the icon gets always updated if needed,
regardless of whether there's an active connection or not.

This is needed because there's at least one case when an icon should
be shown when the computer is not connected to any network: when a
hotspot has been enabled, which can be useful even if there's not
an internet connection to share (e.g. to easily allow connecting
other devices to the computer.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/214
js/ui/status/network.js

index 54ed5cabc7b7512674b56b8f5dc6717267ce031d..a75993612b5b0418b26306afe5797f8636ea0ed7 100644 (file)
@@ -1944,6 +1944,7 @@ var NMApplet = new Lang.Class({
         this.indicators.visible = this._client.nm_running;
         this.menu.actor.visible = this._client.networking_enabled;
 
+        this._updateIcon();
         this._syncConnectivity();
     },